#!/bin/bash

su -c "pushd .; export WORKON_HOME=~/.venvs; source ~/.local/bin/virtualenvwrapper.sh; workon ride_scale_client; popd; python -OO -m scale_client --disable-log-module topology_manager.sdn_topology urllib3.connectionpool --raise-errors  --enable-log-module coapthon  -q 30 --log debug --applications '{\"EdgeSeismicServer\": {\"output_events_file\": \"results/outputs_2t_0.10f_2s_2p_steiner_disjoint_tiny_0.00e_importance/run0/srv\", \"class\":
\"seismic_warning_test.seismic_alert_server.SeismicAlertServer\"}}' \
--networks '{\"CoapServer\": {\"events_root\": \"/events/\", \"class\": \"coap_server.CoapServer\"}}'   --event-sinks '{\"RideD\": {\"tree_construction_algorithm\": [\"steiner\"], \"ntrees\": 2, \"topology_mgr\": {\"username\": \"karaf\", \"controller_ip\": \"10.0.2.15\", \"password\": \"karaf\", \"controller_port\": 8181, \"topology_adapter_type\": \"onos\"}, \"addresses\": [[\"224.0.0.1\", 4000], [\"224.0.0.2\", 4001]], \"multicast\": true, \"tree_choosing_heuristic\": \"importance\",
\"dpid\": \"00:55:00:00:00:00/None\", \"class\": \"seismic_warning_test.ride_d_event_sink.RideDEventSink\", \"maintenance_interval\": 5}}'  " vagrant
# '{\"RideC\": {\"publishers\": [[\"10.131.0.1\", 7777], [\"10.131.0.1\", 7778], [\"10.144.0.2\", 7777], [\"10.144.0.2\", 7778]], \"cloud_server\": \"00:CC:00:00:00:00/None\", \"topology_mgr\": {\"username\": \"karaf\", \"controller_ip\": \"10.0.2.15\", \"password\": \"karaf\", \"controller_port\": 8181, \"topology_adapter_type\": \"onos\"}, \"reroute_policy\": \"disjoint\", \"edge_server\": \"00:55:00:00:00:00/None\", \"class\": \"seismic_warning_test.ride_c_application.RideCApplication\", \"data_paths\": [[\"g1\", \"of:e000000000000001\", \"00:CC:00:00:00:00/None\", 9900], [\"g0\", \"of:e000000000000000\", \"00:CC:00:00:00:00/None\", 9901]]}}' \
